package spring.decorator;

import spring.inters.HelloApi;

public class HelloApiDecorator implements HelloApi {
    private HelloApi helloApi;

    public HelloApiDecorator() {

    }

    public HelloApiDecorator(HelloApi helloApi) {
        this.setHelloApi(helloApi);
    }

    @Override
    public void sayHello() {
        System.out.println("==say start==");
        helloApi.sayHello();
        System.out.println("==say end==");
    }

    public HelloApi getHelloApi() {
        return helloApi;
    }

    public void setHelloApi(HelloApi helloApi) {
        this.helloApi = helloApi;
    }

}
